home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / include / nkcache / nsICacheVisitor.h < prev   
C/C++ Source or Header  |  2006-05-08  |  16KB  |  454 lines

  1. /*
  2.  * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsICacheVisitor.idl
  3.  */
  4.  
  5. #ifndef __gen_nsICacheVisitor_h__
  6. #define __gen_nsICacheVisitor_h__
  7.  
  8.  
  9. #ifndef __gen_nsISupports_h__
  10. #include "nsISupports.h"
  11. #endif
  12.  
  13. /* For IDL files that don't want to include root IDL files. */
  14. #ifndef NS_NO_VTABLE
  15. #define NS_NO_VTABLE
  16. #endif
  17. class nsICacheDeviceInfo; /* forward declaration */
  18.  
  19. class nsICacheEntryInfo; /* forward declaration */
  20.  
  21.  
  22. /* starting interface:    nsICacheVisitor */
  23. #define NS_ICACHEVISITOR_IID_STR "f8c08c4b-d778-49d1-a59b-866fdc500d95"
  24.  
  25. #define NS_ICACHEVISITOR_IID \
  26.   {0xf8c08c4b, 0xd778, 0x49d1, \
  27.     { 0xa5, 0x9b, 0x86, 0x6f, 0xdc, 0x50, 0x0d, 0x95 }}
  28.  
  29. class NS_NO_VTABLE nsICacheVisitor : public nsISupports {
  30.  public: 
  31.  
  32.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ICACHEVISITOR_IID)
  33.  
  34.   /**
  35.      * Called to provide information about a cache device.
  36.      *
  37.      * @param deviceID - specifies the device being visited.
  38.      * @param deviceInfo - specifies information about this device.
  39.      *
  40.      * @return true to start visiting all entries for this device.
  41.      * @return false to advance to the next device.
  42.      */
  43.   /* boolean visitDevice (in string deviceID, in nsICacheDeviceInfo deviceInfo); */
  44.   NS_IMETHOD VisitDevice(const char *deviceID, nsICacheDeviceInfo *deviceInfo, PRBool *_retval) = 0;
  45.  
  46.   /**
  47.      * Called to provide information about a cache entry.
  48.      *
  49.      * @param deviceID - specifies the device being visited.
  50.      * @param entryInfo - specifies information about this entry.
  51.      * 
  52.      * @return true to visit the next entry on the current device, or if the
  53.      *   end of the device has been reached, advance to the next device.
  54.      * @return false to advance to the next device.
  55.      */
  56.   /* boolean visitEntry (in string deviceID, in nsICacheEntryInfo entryInfo); */
  57.   NS_IMETHOD VisitEntry(const char *deviceID, nsICacheEntryInfo *entryInfo, PRBool *_retval) = 0;
  58.  
  59. };
  60.  
  61. /* Use this macro when declaring classes that implement this interface. */
  62. #define NS_DECL_NSICACHEVISITOR \
  63.   NS_IMETHOD VisitDevice(const char *deviceID, nsICacheDeviceInfo *deviceInfo, PRBool *_retval); \
  64.   NS_IMETHOD VisitEntry(const char *deviceID, nsICacheEntryInfo *entryInfo, PRBool *_retval); 
  65.  
  66. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  67. #define NS_FORWARD_NSICACHEVISITOR(_to) \
  68.   NS_IMETHOD VisitDevice(const char *deviceID, nsICacheDeviceInfo *deviceInfo, PRBool *_retval) { return _to VisitDevice(deviceID, deviceInfo, _retval); } \
  69.   NS_IMETHOD VisitEntry(const char *deviceID, nsICacheEntryInfo *entryInfo, PRBool *_retval) { return _to VisitEntry(deviceID, entryInfo, _retval); } 
  70.  
  71. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  72. #define NS_FORWARD_SAFE_NSICACHEVISITOR(_to) \
  73.   NS_IMETHOD VisitDevice(const char *deviceID, nsICacheDeviceInfo *deviceInfo, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->VisitDevice(deviceID, deviceInfo, _retval); } \
  74.   NS_IMETHOD VisitEntry(const char *deviceID, nsICacheEntryInfo *entryInfo, PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->VisitEntry(deviceID, entryInfo, _retval); } 
  75.  
  76. #if 0
  77. /* Use the code below as a template for the implementation class for this interface. */
  78.  
  79. /* Header file */
  80. class nsCacheVisitor : public nsICacheVisitor
  81. {
  82. public:
  83.   NS_DECL_ISUPPORTS
  84.   NS_DECL_NSICACHEVISITOR
  85.  
  86.   nsCacheVisitor();
  87.  
  88. private:
  89.   ~nsCacheVisitor();
  90.  
  91. protected:
  92.   /* additional members */
  93. };
  94.  
  95. /* Implementation file */
  96. NS_IMPL_ISUPPORTS1(nsCacheVisitor, nsICacheVisitor)
  97.  
  98. nsCacheVisitor::nsCacheVisitor()
  99. {
  100.   /* member initializers and constructor code */
  101. }
  102.  
  103. nsCacheVisitor::~nsCacheVisitor()
  104. {
  105.   /* destructor code */
  106. }
  107.  
  108. /* boolean visitDevice (in string deviceID, in nsICacheDeviceInfo deviceInfo); */
  109. NS_IMETHODIMP nsCacheVisitor::VisitDevice(const char *deviceID, nsICacheDeviceInfo *deviceInfo, PRBool *_retval)
  110. {
  111.     return NS_ERROR_NOT_IMPLEMENTED;
  112. }
  113.  
  114. /* boolean visitEntry (in string deviceID, in nsICacheEntryInfo entryInfo); */
  115. NS_IMETHODIMP nsCacheVisitor::VisitEntry(const char *deviceID, nsICacheEntryInfo *entryInfo, PRBool *_retval)
  116. {
  117.     return NS_ERROR_NOT_IMPLEMENTED;
  118. }
  119.  
  120. /* End of implementation class template. */
  121. #endif
  122.  
  123.  
  124. /* starting interface:    nsICacheDeviceInfo */
  125. #define NS_ICACHEDEVICEINFO_IID_STR "31d1c294-1dd2-11b2-be3a-c79230dca297"
  126.  
  127. #define NS_ICACHEDEVICEINFO_IID \
  128.   {0x31d1c294, 0x1dd2, 0x11b2, \
  129.     { 0xbe, 0x3a, 0xc7, 0x92, 0x30, 0xdc, 0xa2, 0x97 }}
  130.  
  131. class NS_NO_VTABLE nsICacheDeviceInfo : public nsISupports {
  132.  public: 
  133.  
  134.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ICACHEDEVICEINFO_IID)
  135.  
  136.   /**
  137.      * Get a human readable description of the cache device.
  138.      */
  139.   /* readonly attribute string description; */
  140.   NS_IMETHOD GetDescription(char * *aDescription) = 0;
  141.  
  142.   /**
  143.      * Get a usage report, statistics, miscellaneous data about
  144.      * the cache device.
  145.      */
  146.   /* readonly attribute string usageReport; */
  147.   NS_IMETHOD GetUsageReport(char * *aUsageReport) = 0;
  148.  
  149.   /**
  150.      * Get the number of stored cache entries.
  151.      */
  152.   /* readonly attribute unsigned long entryCount; */
  153.   NS_IMETHOD GetEntryCount(PRUint32 *aEntryCount) = 0;
  154.  
  155.   /**
  156.      * Get the total size of the stored cache entries.
  157.      */
  158.   /* readonly attribute unsigned long totalSize; */
  159.   NS_IMETHOD GetTotalSize(PRUint32 *aTotalSize) = 0;
  160.  
  161.   /**
  162.      * Get the upper limit of the size of the data the cache can store.
  163.      */
  164.   /* readonly attribute unsigned long maximumSize; */
  165.   NS_IMETHOD GetMaximumSize(PRUint32 *aMaximumSize) = 0;
  166.  
  167. };
  168.  
  169. /* Use this macro when declaring classes that implement this interface. */
  170. #define NS_DECL_NSICACHEDEVICEINFO \
  171.   NS_IMETHOD GetDescription(char * *aDescription); \
  172.   NS_IMETHOD GetUsageReport(char * *aUsageReport); \
  173.   NS_IMETHOD GetEntryCount(PRUint32 *aEntryCount); \
  174.   NS_IMETHOD GetTotalSize(PRUint32 *aTotalSize); \
  175.   NS_IMETHOD GetMaximumSize(PRUint32 *aMaximumSize); 
  176.  
  177. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  178. #define NS_FORWARD_NSICACHEDEVICEINFO(_to) \
  179.   NS_IMETHOD GetDescription(char * *aDescription) { return _to GetDescription(aDescription); } \
  180.   NS_IMETHOD GetUsageReport(char * *aUsageReport) { return _to GetUsageReport(aUsageReport); } \
  181.   NS_IMETHOD GetEntryCount(PRUint32 *aEntryCount) { return _to GetEntryCount(aEntryCount); } \
  182.   NS_IMETHOD GetTotalSize(PRUint32 *aTotalSize) { return _to GetTotalSize(aTotalSize); } \
  183.   NS_IMETHOD GetMaximumSize(PRUint32 *aMaximumSize) { return _to GetMaximumSize(aMaximumSize); } 
  184.  
  185. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  186. #define NS_FORWARD_SAFE_NSICACHEDEVICEINFO(_to) \
  187.   NS_IMETHOD GetDescription(char * *aDescription) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDescription(aDescription); } \
  188.   NS_IMETHOD GetUsageReport(char * *aUsageReport) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetUsageReport(aUsageReport); } \
  189.   NS_IMETHOD GetEntryCount(PRUint32 *aEntryCount) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetEntryCount(aEntryCount); } \
  190.   NS_IMETHOD GetTotalSize(PRUint32 *aTotalSize) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTotalSize(aTotalSize); } \
  191.   NS_IMETHOD GetMaximumSize(PRUint32 *aMaximumSize) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetMaximumSize(aMaximumSize); } 
  192.  
  193. #if 0
  194. /* Use the code below as a template for the implementation class for this interface. */
  195.  
  196. /* Header file */
  197. class nsCacheDeviceInfo : public nsICacheDeviceInfo
  198. {
  199. public:
  200.   NS_DECL_ISUPPORTS
  201.   NS_DECL_NSICACHEDEVICEINFO
  202.  
  203.   nsCacheDeviceInfo();
  204.  
  205. private:
  206.   ~nsCacheDeviceInfo();
  207.  
  208. protected:
  209.   /* additional members */
  210. };
  211.  
  212. /* Implementation file */
  213. NS_IMPL_ISUPPORTS1(nsCacheDeviceInfo, nsICacheDeviceInfo)
  214.  
  215. nsCacheDeviceInfo::nsCacheDeviceInfo()
  216. {
  217.   /* member initializers and constructor code */
  218. }
  219.  
  220. nsCacheDeviceInfo::~nsCacheDeviceInfo()
  221. {
  222.   /* destructor code */
  223. }
  224.  
  225. /* readonly attribute string description; */
  226. NS_IMETHODIMP nsCacheDeviceInfo::GetDescription(char * *aDescription)
  227. {
  228.     return NS_ERROR_NOT_IMPLEMENTED;
  229. }
  230.  
  231. /* readonly attribute string usageReport; */
  232. NS_IMETHODIMP nsCacheDeviceInfo::GetUsageReport(char * *aUsageReport)
  233. {
  234.     return NS_ERROR_NOT_IMPLEMENTED;
  235. }
  236.  
  237. /* readonly attribute unsigned long entryCount; */
  238. NS_IMETHODIMP nsCacheDeviceInfo::GetEntryCount(PRUint32 *aEntryCount)
  239. {
  240.     return NS_ERROR_NOT_IMPLEMENTED;
  241. }
  242.  
  243. /* readonly attribute unsigned long totalSize; */
  244. NS_IMETHODIMP nsCacheDeviceInfo::GetTotalSize(PRUint32 *aTotalSize)
  245. {
  246.     return NS_ERROR_NOT_IMPLEMENTED;
  247. }
  248.  
  249. /* readonly attribute unsigned long maximumSize; */
  250. NS_IMETHODIMP nsCacheDeviceInfo::GetMaximumSize(PRUint32 *aMaximumSize)
  251. {
  252.     return NS_ERROR_NOT_IMPLEMENTED;
  253. }
  254.  
  255. /* End of implementation class template. */
  256. #endif
  257.  
  258.  
  259. /* starting interface:    nsICacheEntryInfo */
  260. #define NS_ICACHEENTRYINFO_IID_STR "fab51c92-95c3-4468-b317-7de4d7588254"
  261.  
  262. #define NS_ICACHEENTRYINFO_IID \
  263.   {0xfab51c92, 0x95c3, 0x4468, \
  264.     { 0xb3, 0x17, 0x7d, 0xe4, 0xd7, 0x58, 0x82, 0x54 }}
  265.  
  266. class NS_NO_VTABLE nsICacheEntryInfo : public nsISupports {
  267.  public: 
  268.  
  269.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ICACHEENTRYINFO_IID)
  270.  
  271.   /**
  272.      * Get the client id associated with this cache entry.
  273.      */
  274.   /* readonly attribute string clientID; */
  275.   NS_IMETHOD GetClientID(char * *aClientID) = 0;
  276.  
  277.   /**
  278.      * Get the id for the device that stores this cache entry.
  279.      */
  280.   /* readonly attribute string deviceID; */
  281.   NS_IMETHOD GetDeviceID(char * *aDeviceID) = 0;
  282.  
  283.   /**
  284.      * Get the key identifying the cache entry.
  285.      */
  286.   /* readonly attribute ACString key; */
  287.   NS_IMETHOD GetKey(nsACString & aKey) = 0;
  288.  
  289.   /**
  290.      * Get the number of times the cache entry has been opened.
  291.      */
  292.   /* readonly attribute long fetchCount; */
  293.   NS_IMETHOD GetFetchCount(PRInt32 *aFetchCount) = 0;
  294.  
  295.   /**
  296.      * Get the last time the cache entry was opened (in seconds since the Epoch).
  297.      */
  298.   /* readonly attribute PRUint32 lastFetched; */
  299.   NS_IMETHOD GetLastFetched(PRUint32 *aLastFetched) = 0;
  300.  
  301.   /**
  302.      * Get the last time the cache entry was modified (in seconds since the Epoch).
  303.      */
  304.   /* readonly attribute PRUint32 lastModified; */
  305.   NS_IMETHOD GetLastModified(PRUint32 *aLastModified) = 0;
  306.  
  307.   /**
  308.      * Get the expiration time of the cache entry (in seconds since the Epoch).
  309.      */
  310.   /* readonly attribute PRUint32 expirationTime; */
  311.   NS_IMETHOD GetExpirationTime(PRUint32 *aExpirationTime) = 0;
  312.  
  313.   /**
  314.      * Get the cache entry data size.
  315.      */
  316.   /* readonly attribute unsigned long dataSize; */
  317.   NS_IMETHOD GetDataSize(PRUint32 *aDataSize) = 0;
  318.  
  319.   /**
  320.      * Find out whether or not the cache entry is stream based.
  321.      */
  322.   /* boolean isStreamBased (); */
  323.   NS_IMETHOD IsStreamBased(PRBool *_retval) = 0;
  324.  
  325. };
  326.  
  327. /* Use this macro when declaring classes that implement this interface. */
  328. #define NS_DECL_NSICACHEENTRYINFO \
  329.   NS_IMETHOD GetClientID(char * *aClientID); \
  330.   NS_IMETHOD GetDeviceID(char * *aDeviceID); \
  331.   NS_IMETHOD GetKey(nsACString & aKey); \
  332.   NS_IMETHOD GetFetchCount(PRInt32 *aFetchCount); \
  333.   NS_IMETHOD GetLastFetched(PRUint32 *aLastFetched); \
  334.   NS_IMETHOD GetLastModified(PRUint32 *aLastModified); \
  335.   NS_IMETHOD GetExpirationTime(PRUint32 *aExpirationTime); \
  336.   NS_IMETHOD GetDataSize(PRUint32 *aDataSize); \
  337.   NS_IMETHOD IsStreamBased(PRBool *_retval); 
  338.  
  339. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  340. #define NS_FORWARD_NSICACHEENTRYINFO(_to) \
  341.   NS_IMETHOD GetClientID(char * *aClientID) { return _to GetClientID(aClientID); } \
  342.   NS_IMETHOD GetDeviceID(char * *aDeviceID) { return _to GetDeviceID(aDeviceID); } \
  343.   NS_IMETHOD GetKey(nsACString & aKey) { return _to GetKey(aKey); } \
  344.   NS_IMETHOD GetFetchCount(PRInt32 *aFetchCount) { return _to GetFetchCount(aFetchCount); } \
  345.   NS_IMETHOD GetLastFetched(PRUint32 *aLastFetched) { return _to GetLastFetched(aLastFetched); } \
  346.   NS_IMETHOD GetLastModified(PRUint32 *aLastModified) { return _to GetLastModified(aLastModified); } \
  347.   NS_IMETHOD GetExpirationTime(PRUint32 *aExpirationTime) { return _to GetExpirationTime(aExpirationTime); } \
  348.   NS_IMETHOD GetDataSize(PRUint32 *aDataSize) { return _to GetDataSize(aDataSize); } \
  349.   NS_IMETHOD IsStreamBased(PRBool *_retval) { return _to IsStreamBased(_retval); } 
  350.  
  351. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  352. #define NS_FORWARD_SAFE_NSICACHEENTRYINFO(_to) \
  353.   NS_IMETHOD GetClientID(char * *aClientID) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetClientID(aClientID); } \
  354.   NS_IMETHOD GetDeviceID(char * *aDeviceID) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDeviceID(aDeviceID); } \
  355.   NS_IMETHOD GetKey(nsACString & aKey) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetKey(aKey); } \
  356.   NS_IMETHOD GetFetchCount(PRInt32 *aFetchCount) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFetchCount(aFetchCount); } \
  357.   NS_IMETHOD GetLastFetched(PRUint32 *aLastFetched) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLastFetched(aLastFetched); } \
  358.   NS_IMETHOD GetLastModified(PRUint32 *aLastModified) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLastModified(aLastModified); } \
  359.   NS_IMETHOD GetExpirationTime(PRUint32 *aExpirationTime) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetExpirationTime(aExpirationTime); } \
  360.   NS_IMETHOD GetDataSize(PRUint32 *aDataSize) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDataSize(aDataSize); } \
  361.   NS_IMETHOD IsStreamBased(PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsStreamBased(_retval); } 
  362.  
  363. #if 0
  364. /* Use the code below as a template for the implementation class for this interface. */
  365.  
  366. /* Header file */
  367. class nsCacheEntryInfo : public nsICacheEntryInfo
  368. {
  369. public:
  370.   NS_DECL_ISUPPORTS
  371.   NS_DECL_NSICACHEENTRYINFO
  372.  
  373.   nsCacheEntryInfo();
  374.  
  375. private:
  376.   ~nsCacheEntryInfo();
  377.  
  378. protected:
  379.   /* additional members */
  380. };
  381.  
  382. /* Implementation file */
  383. NS_IMPL_ISUPPORTS1(nsCacheEntryInfo, nsICacheEntryInfo)
  384.  
  385. nsCacheEntryInfo::nsCacheEntryInfo()
  386. {
  387.   /* member initializers and constructor code */
  388. }
  389.  
  390. nsCacheEntryInfo::~nsCacheEntryInfo()
  391. {
  392.   /* destructor code */
  393. }
  394.  
  395. /* readonly attribute string clientID; */
  396. NS_IMETHODIMP nsCacheEntryInfo::GetClientID(char * *aClientID)
  397. {
  398.     return NS_ERROR_NOT_IMPLEMENTED;
  399. }
  400.  
  401. /* readonly attribute string deviceID; */
  402. NS_IMETHODIMP nsCacheEntryInfo::GetDeviceID(char * *aDeviceID)
  403. {
  404.     return NS_ERROR_NOT_IMPLEMENTED;
  405. }
  406.  
  407. /* readonly attribute ACString key; */
  408. NS_IMETHODIMP nsCacheEntryInfo::GetKey(nsACString & aKey)
  409. {
  410.     return NS_ERROR_NOT_IMPLEMENTED;
  411. }
  412.  
  413. /* readonly attribute long fetchCount; */
  414. NS_IMETHODIMP nsCacheEntryInfo::GetFetchCount(PRInt32 *aFetchCount)
  415. {
  416.     return NS_ERROR_NOT_IMPLEMENTED;
  417. }
  418.  
  419. /* readonly attribute PRUint32 lastFetched; */
  420. NS_IMETHODIMP nsCacheEntryInfo::GetLastFetched(PRUint32 *aLastFetched)
  421. {
  422.     return NS_ERROR_NOT_IMPLEMENTED;
  423. }
  424.  
  425. /* readonly attribute PRUint32 lastModified; */
  426. NS_IMETHODIMP nsCacheEntryInfo::GetLastModified(PRUint32 *aLastModified)
  427. {
  428.     return NS_ERROR_NOT_IMPLEMENTED;
  429. }
  430.  
  431. /* readonly attribute PRUint32 expirationTime; */
  432. NS_IMETHODIMP nsCacheEntryInfo::GetExpirationTime(PRUint32 *aExpirationTime)
  433. {
  434.     return NS_ERROR_NOT_IMPLEMENTED;
  435. }
  436.  
  437. /* readonly attribute unsigned long dataSize; */
  438. NS_IMETHODIMP nsCacheEntryInfo::GetDataSize(PRUint32 *aDataSize)
  439. {
  440.     return NS_ERROR_NOT_IMPLEMENTED;
  441. }
  442.  
  443. /* boolean isStreamBased (); */
  444. NS_IMETHODIMP nsCacheEntryInfo::IsStreamBased(PRBool *_retval)
  445. {
  446.     return NS_ERROR_NOT_IMPLEMENTED;
  447. }
  448.  
  449. /* End of implementation class template. */
  450. #endif
  451.  
  452.  
  453. #endif /* __gen_nsICacheVisitor_h__ */
  454.